package com.ruoyi.DegreeCommit.mapper;

import java.util.List;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.DegreeCommit.domain.DegreeCommit;
import org.apache.ibatis.annotations.Select;

/**
 * DegreeCommitMapper接口
 * 
 * @author ruoyi
 * @date 2025-04-23
 */
public interface DegreeCommitMapper extends BaseMapper<DegreeCommit>
{
    /**
     * 查询DegreeCommit
     * 
     * @param id DegreeCommit主键
     * @return DegreeCommit
     */
    public DegreeCommit selectDegreeCommitById(Long id);

    /**
     * 查询DegreeCommit列表
     * 
     * @param degreeCommit DegreeCommit
     * @return DegreeCommit集合
     */
    public List<DegreeCommit> selectDegreeCommitList(DegreeCommit degreeCommit);

    /**
     * 新增DegreeCommit
     * 
     * @param degreeCommit DegreeCommit
     * @return 结果
     */
    public int insertDegreeCommit(DegreeCommit degreeCommit);

    /**
     * 修改DegreeCommit
     * 
     * @param degreeCommit DegreeCommit
     * @return 结果
     */
    public int updateDegreeCommit(DegreeCommit degreeCommit);

    /**
     * 删除DegreeCommit
     * 
     * @param id DegreeCommit主键
     * @return 结果
     */
    public int deleteDegreeCommitById(Long id);

    /**
     * 批量删除DegreeCommit
     * 
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteDegreeCommitByIds(Long[] ids);


    //根据用户ID 查询数据
    @Select("select * from degree_commit where u_id = #{userId}")
    List<DegreeCommit> selectByUId(Long userId);
}
